<html>
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>数据类型</title>
</head>
<body>
    <script>
        // undefined
        var x;
        // alert(x)
        console.log(x)
        var str1 = "hello word";
        var str2 = 'hello word';
        console.log(str1);
        console.log(str2);
        // var str = "hello word";
        var str3 = '小张说:"你最好看"';
        console.log(str3);

        // 字符串替换
        var str = "Java";
        // 1. 下面代码执行顺序 先执行等候右侧代码 然后赋值给左边变量
        // 2. JS字符串的加法是拼接字符串
        str = str + "Script";//放到左侧str过程中str中java被删掉 新的JavaScript放入
        console.log(str);
    </script>
</body>
</html>